package top.scsoul.voes.examination.service;

import com.github.pagehelper.PageInfo;
import top.scsoul.voes.examination.entity.ExamRegistration;
import java.util.List;

/**
 * (ExamRegistration)表服务接口
 *
 * @author guolei
 * @since 2021-07-25 09:47:55
 */
public interface ExamRegistrationService {

    /**
     * 通过ID查询单条数据
     *
     * @param id 主键
     * @return 实例对象
     */
    ExamRegistration queryById(Integer id);
    List<String> queryExamCardNumByExamId(Integer examId);

    /**
     * 查询多条数据
     *
     * @param offset 查询起始位置
     * @param limit 查询条数
     * @return 对象列表
     */
    List<ExamRegistration> queryAllByLimit(int offset, int limit);

    /**
     * 新增数据
     *
     * @param examRegistration 实例对象
     * @return 实例对象
     */
    ExamRegistration insert(ExamRegistration examRegistration);

    /**
     * 修改数据
     *
     * @param examRegistration 实例对象
     * @return 实例对象
     */
    ExamRegistration update(ExamRegistration examRegistration);

    /**
     * 通过主键删除数据
     *
     * @param id 主键
     * @return 是否成功
     */
    boolean deleteById(Integer id);
    PageInfo<ExamRegistration> queryAll(ExamRegistration examRegistration, int currentPage, int pageSize);
    List<ExamRegistration> queryAll(ExamRegistration examRegistration);

    ExamRegistration queryExamRegistrationByUsernameAndExamId(String username , Integer examId);
}